﻿using System;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Linq;
using System.Reflection;
using System.Configuration;

namespace MvcArchStarter.Core.Ioc
{
    /// <summary>
    /// A type finder that uses a configuration file section containing assemblies to 
    /// interrogate for types to add to the container.
    /// </summary>
    public class FindTypesInConfiguration : BaseTypeFinder
    {
        private const string CONFIG_SECTION = "IocDiscoveryAssemblies";
        /// <summary>
        /// The types found in the assemblies.
        /// </summary>
        /// <returns></returns>
        public override Type[] GetTypes()
        {
            this.ConfigSection = CONFIG_SECTION; 
            return base.GetTypes(); 
        }

    }
}
